<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
	<title>推荐奖励储值管理</title>
	<meta name="decorator" content="default"/>
	<script type="text/javascript">
		$(document).ready(function() {
			
		});
		function page(n,s){
			$("#pageNo").val(n);
			$("#pageSize").val(s);
			$("#searchForm").submit();
        	return false;
        }
	</script>
</head>
<body>
	<ul class="nav nav-tabs">
		<li class="active"><a href="${ctx}/recharge/rechargeCache/">推荐奖励储值列表</a></li>
	</ul>
	<form:form id="searchForm" modelAttribute="rechargeCache" action="${ctx}/recharge/rechargeCache/" method="post" class="breadcrumb form-search">
		<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
		<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
		<label>名称 ：</label><form:input path="name" htmlEscape="false" maxlength="50" class="input-medium"/>
		<label>会员电话 ：</label><form:input path="parentMember.mobile" htmlEscape="false" maxlength="50" class="input-medium"/>
		&nbsp;<input id="btnSubmit" class="btn btn-primary" type="submit" value="查询"/>
	</form:form>
	<tags:message content="${message}"/>
	<table id="contentTable" class="table table-striped table-bordered ">
		<thead><tr><th>姓名</th><th>金额(元)</th><th>类型</th><th>状态</th><th>时间</th><th>备注</th><shiro:hasPermission name="recharge:rechargeCache:edit"><th>操作</th></shiro:hasPermission></tr></thead>
		<tbody>
		<c:forEach items="${page.list}" var="rechargeCache">
			<tr>
				<td>${rechargeCache.name}</td>
				<td>
					<c:if test="${rechargeCache.money eq null}">0</c:if>
		          	<c:if test="${rechargeCache.money ne null}">
		          		<c:if test="${rechargeCache.money eq 0}">0</c:if>
		          		<c:if test="${rechargeCache.money ne 0}">
				       		<fmt:formatNumber value="${rechargeCache.money/100}" pattern="##.##"  minFractionDigits="2"/>
		          		</c:if>
		          	</c:if>
					
				</td>
				<td>${rechargeCache.type==0?'奖励':""}</td>
				<td>${rechargeCache.status==0?'未激活':'激活'}</td>
				<td>${rechargeCache.createTime}</td>
				<td>${rechargeCache.remarks}</td>
				<shiro:hasPermission name="recharge:rechargeCache:edit"><td>
					<a class="btn btn-success" href="${ctx}/recharge/rechargeCache/activate?id=${rechargeCache.id}"  onclick="return confirmx('确认要激活吗？', this.href)">激活</a>
					<a class="btn btn-danger" href="${ctx}/recharge/rechargeCache/delete?id=${rechargeCache.id}" onclick="return confirmx('确认要删除该推荐奖励储值吗？', this.href)">删除</a>
				</td></shiro:hasPermission>
			</tr>
		</c:forEach>
		</tbody>
	</table>
	<div class="pagination">${page}</div>
</body>
</html>
